//
//  JGOrderToSetController.m
//  JGRider
//
//  Created by 单启志 on 2018/1/30.
//  Copyright © 2018年 ffq. All rights reserved.
//

#import "JGOrderToSetController.h"
#import "JGOrderToSetContentView.h"
#import <MOFSPickerManager.h>
@interface JGOrderToSetController ()<OrderToSetContentViewDelegate>
@property(nonatomic,strong)JGOrderToSetContentView *conView;
@end

@implementation JGOrderToSetController

- (void)viewDidLoad {
    [super viewDidLoad];

    [self configSubViews];

}

-(void)configSubViews{
    self.title=@"接单设置";
    [self.view addSubview:self.conView];
}
#pragma mark - contentView delegate
//当前定点
-(void)ChangeAddressEvent:(UIButton *)eventBtn{

    self.conView.address=@"长林王府";
}

//接单范围
-(void)changeScopeEvent:(UIButton *)eventBtn{
    [[MOFSPickerManager shareManger]showPickerViewWithDataArray:@[@"3KM以下",@"3-5KM",@"5-7KM"] tag:0 title:@"接单范围" cancelTitle:@"取消" commitTitle:@"完成" commitBlock:^(NSString *string) {

    } cancelBlock:^{

    }];
}

#pragma mark - setters
-(JGOrderToSetContentView *)conView{

    if (!_conView) {
        _conView=[[JGOrderToSetContentView alloc]initWithFrame:CGRectMake(0, self.lmj_navgationBar.height, JGScreenW, JGScreenH-self.lmj_navgationBar.height)];
        _conView.delegate=self;
    }
    return _conView;
}

- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    
}


@end
